package com.lq.demo.demo.mode.limit;

import com.google.common.util.concurrent.RateLimiter;
import org.springframework.stereotype.Component;


@Component
public class GuavaLimitSimpalDemo {

    private static final RateLimiter rateLimit = RateLimiter.create(10);

    public boolean tryAcquire() {
        return rateLimit.tryAcquire();
    }

}
